package com.quartet.modules.stock.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.quartet.modules.statistics.dto.DataStatisticsGroupByTimeResponseDto;
import com.quartet.modules.statistics.dto.DataStatisticsRequestDto;
import com.quartet.modules.statistics.dto.StatisticsRequestDto;
import com.quartet.modules.stock.dto.TTerminalCountGroupByCustomerDto;
import com.quartet.modules.stock.dto.TTerminalServiceMessageDto;
import com.quartet.modules.stock.entity.TTerminalStock;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 终端库存表(TTerminalStock)表数据库访问层
 *
 * @author makejava
 * @since 2021-06-20 09:07:33
 */
public interface TTerminalStockDao extends BaseMapper<TTerminalStock> {

    /**
     * 查询设备订单信息
     * @return
     * @param orderCodeList
     */
    List<TTerminalServiceMessageDto> queryTerminalOrder(@Param("orderCodeList") List<String> orderCodeList);

    /**
     * 查询设备订单信息
     * @return
     * @param statisticsRequestDto
     */
    List<TTerminalCountGroupByCustomerDto> queryTerminalCountGroupCustomer(StatisticsRequestDto statisticsRequestDto);

    /**
     * 按照小时查询设备数
     * @return
     * @param dataStatisticsRequestDto
     */
    List<DataStatisticsGroupByTimeResponseDto> queryTerminalCountGroupTimeHour(DataStatisticsRequestDto dataStatisticsRequestDto);

    /**
     *  按照天查询设备数
     * @param dataStatisticsRequestDto
     * @return
     */
    List<DataStatisticsGroupByTimeResponseDto> queryTerminalCountGroupTimeDay(DataStatisticsRequestDto dataStatisticsRequestDto);

    /**
     *  按照月查询设备数
     * @param dataStatisticsRequestDto
     * @return
     */
    List<DataStatisticsGroupByTimeResponseDto> queryTerminalCountGroupTimeMonth(DataStatisticsRequestDto dataStatisticsRequestDto);
}
